home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Power Programmierung
/
Power-Programmierung (Tewi)(1994).iso
/
magazine
/
progjour
/
1988
/
01
/
listing2.c
< prev
next >
Wrap
Text File
|
1987-12-28
|
640b
|
22 lines
/*
* gettix.c -- Gets the current timer tick from the BIOS in two ways:
*
* 1.) Through the BIOS - The preferred way
* 2.) Directly via a far pointer - The unrecommended way
* Copyright Frank D. Greco, 1987
* Page 50, Volume 6.1 Programmer's Journal
*/
#include <dos.h>
main()
{
unsigned long gettime();
long far *fp;
FP_SEG(fp) = 0x0040;
FP_OFF(fp) = 0x006C;
printf("BIOS: %lu Thru far ptr: %lu\n", gettime(), *fp);
}